import styles from '../styles.less';
import {Card, Tabs} from 'antd';
import {useState} from 'react';
import BaseInfoForm from './BaseInfoForm';
import ModifyPassForm from './ModifyPassForm';

const RightContent = () => {

  const [activeKey, setActiveKey] = useState('1');

  const onChange = (key) => {
    setActiveKey(key);
  };

  const tabItems = [
    {key: '1', label: `基本资料`, children: <BaseInfoForm/>},
    {key: '2', label: `修改密码`, children: <ModifyPassForm/>},
  ];

  return (
    <Card bordered={false} className={styles.rightContent}>
      <Tabs activeKey={activeKey} items={tabItems} onChange={onChange}/>
    </Card>
  );
};

export default RightContent;
